home *** CD-ROM | disk | FTP | other *** search
- VERSION 4.00
- Begin VB.Form FindValName
- BorderStyle = 1 'Fixed Single
- Caption = "Find Value Name"
- ClientHeight = 2535
- ClientLeft = 2760
- ClientTop = 5955
- ClientWidth = 4995
- ClipControls = 0 'False
- Height = 3000
- Left = 2670
- LinkTopic = "Form1"
- ScaleHeight = 2535
- ScaleWidth = 4995
- Top = 5580
- Width = 5175
- Begin VB.CommandButton ButtonStart
- Caption = "Find"
- Height = 375
- Left = 3600
- TabIndex = 8
- Top = 2040
- Width = 1215
- End
- Begin VB.CommandButton ButtonCancel
- Cancel = -1 'True
- Caption = "Close"
- Height = 375
- Left = 2280
- TabIndex = 7
- Top = 2040
- Width = 1215
- End
- Begin VB.Frame Frame1
- Caption = "Search Area"
- ClipControls = 0 'False
- Height = 855
- Left = 120
- TabIndex = 4
- Top = 960
- Width = 4695
- Begin VB.OptionButton OptRoot
- Caption = "Start Search at Root"
- Height = 255
- Left = 240
- TabIndex = 6
- Top = 360
- Width = 1935
- End
- Begin VB.OptionButton OptCurrent
- Caption = "Start Search at Current Key"
- Height = 255
- Left = 2280
- TabIndex = 5
- Top = 360
- Value = -1 'True
- Width = 2295
- End
- End
- Begin VB.CheckBox ChkWhole
- Caption = "Match Whole Name Only"
- Height = 375
- Left = 2640
- TabIndex = 3
- Top = 480
- Width = 2175
- End
- Begin VB.CheckBox ChkCase
- Caption = "Match Case "
- Height = 375
- Left = 480
- TabIndex = 2
- Top = 480
- Width = 1815
- End
- Begin VB.TextBox KeyText
- Height = 285
- Left = 2040
- TabIndex = 1
- Top = 120
- Width = 2775
- End
- Begin VB.Label Label1
- BackStyle = 0 'Transparent
- Caption = "Value Name to Look For:"
- Height = 255
- Left = 120
- TabIndex = 0
- Top = 120
- Width = 1815
- End
- Attribute VB_Name = "FindValName"
- Attribute VB_Creatable = False
- Attribute VB_Exposed = False
- Option Explicit
- ' Close Button. Unloades the dialog box.
- Private Sub ButtonCancel_Click()
- Unload FindValName
- End Sub
- ' Find Button. Finds al the keys and values that
- ' match and inserts them into the Results form
- ' to be viewed.
- Private Sub ButtonStart_Click()
- Dim sCase As Boolean
- Dim whole As Boolean
- Dim AtRoot As Boolean
- Dim RetVal As Boolean
- sCase = (ChkCase.Value = 1)
- whole = (ChkWhole.Value = 1)
- AtRoot = OptRoot.Value
- FindValName.MousePointer = 11
- RetVal = BaseForm.Registry1.FindFirstValueName(KeyText, sCase, whole, AtRoot)
- If RetVal = False Then
- MsgBox ("There are no values in this root that match.")
- FindValName.MousePointer = 0
- Exit Sub
- End If
- FindValName.MousePointer = 0
- FindResults.listresults.Clear
- Do
- FindResults.listresults.AddItem "KEY: " & BaseForm.Registry1.FindResultKey
- FindResults.listresults.AddItem "VALUE NAME: " & BaseForm.Registry1.FindResultValueName
- FindResults.listresults.AddItem ""
- Loop While BaseForm.Registry1.FindNextValueName() = True
- FindResults.Show
- Exit Sub
- End Sub
-